View Issue Details

IDProjectCategoryView StatusLast Update
0001907T99X171.00 SKB EagleSWpublic2024-07-11 13:46
Reporter(ALTech) Sangmin Choi Assigned To(ALTech) Sangmin Choi Due Date2024-07-12 13:00
PrioritynormalSeveritys4-minorReproducibilityN/A
Status closedResolutionreopened 
Summary0001907: Apply dynamic custom code for remote control.
DescriptionSKB has plan to implement custom code changing feature.

Now, the STB can get the IR code if the custom code of IR code is 0x807f or 0xf5a0.
SKB want to maintain the 0x807f custom code.
And, they want to change 0xf5a0 custom code refer to the Android persist property from the boot time.

This feature is going to apply when the development of 542 firmware is done.
So, we should prepare how to implement it.
TagsNo tags attached.
Attach Tags

Users monitoring this issue

Activities

(ALTech) Sangmin Choi

2024-03-26 13:12

developer   ~0015299

Hello, Kerwin,

Could you please check this ticket?

First, please find the way how to change custom code dynamically.

If you have any question, please let me know.

Thank you.
Sangmin Choi.

(SW) Kerwin Chen

2024-03-26 15:02

developer   ~0015304

Hi Mr. Sangmin Choi,

A few question for the request:
1. '0x7f80' will be kept and only '0xa0f5' will be changed, is it correct ?
2. Does system need to reboot to take effect after SKB changes the custom code ?

The parsing of keymap is done in kernel driver init, I think system reboot is necessary.
You can check Amlogic remote source codes in "common/drivers/amlogic/input/remote/" .

Thank you!

(SW) Kerwin Chen

2024-03-26 15:17

developer   ~0015305

Last edited: 2024-03-26 15:18

Hi Mr. Sangmin Choi,

One more thing, currectly RCU works in IR mode under passive standby mode.
If custom code is changed, power key may not work because the key is stored in another place.
You may need to have AML's comments for this change.

bootloader/uboot-repo/bl33/v2015/arch/arm/cpu/armv8/g12a/firmware/scp_task/scp_remote.c

(ALTech) Sangmin Choi

2024-03-26 15:37

developer   ~0015307

Last edited: 2024-03-26 16:07

Hello, Kerwin,

1. '0x807f' will be kept and only '0xf5a0' will be changed, is it correct ?
    -> yes, correct.
    -> The integer value is stored in persist.sys.rcu.custom_ir_idx and 0xf5a0 will be changed to (0xf5a0 + persist.sys.rcu.custom_ir_idx)
        Above is a draft version so please just check their idea.
        if persist.sys.rcu.custom_ir_idx is 1, the 0xf5a0 will be changed 0xf5a1
        if persist.sys.rcu.custom_ir_idx is 2, the 0xf5a0 will be changed 0xf5a2
        ...
        persist.sys.rcu.custom_ir_idx maximum value is 99.

2. Does system need to reboot to take effect after SKB changes the custom code ?
    -> yes, the changed custom code will be applied after reboot.

3. One more thing, currectly RCU works in IR mode under passive standby mode.
    -> Thank you, I didn't consider it. I will check it with SKB manager

Thank you.
Sangmin Choi.

(ALTech) Sangmin Choi

2024-03-26 16:06

developer   ~0015308

Hello, Kerwin,

I want to define the custom code again. I will modify them in this ticket.
0x7f80 -> 0x807f
0xa0f5 -> 0xf5a0

And, for passive standby mode, how about this solution?
The persist.sys.rcu.custom_ir_idx range is 0 to 99.
So, the custom code range is 0xf5a0 to 0xF608.
We can add 99 keycodes to kk variable, it looks not a smart but it's worth a try.

Thank you.
Sangmin Choi.

(SW) Kerwin Chen

2024-03-26 16:48

developer   ~0015309

Hi Mr. Sangmin Choi,

It the rule is confirmed, it should be ok.
Do you know which program will set "persist.sys.rcu.custom_ir_idx" property?

(ALTech) Sangmin Choi

2024-03-26 17:06

developer   ~0015310

Hello, Kerwin,

persist.sys.rcu.custom_ir_idx will be set by MW, I guess.
The hidden UI will be added to set this property.

I will let you know when the detail specification is fixed.
And, can you expect how many working dates do you need for this feature?

(SW) Kerwin Chen

2024-03-27 08:42

developer   ~0015312

Hi Mr. Sangmin Choi,

If persist.sys.rcu.custom_ir_idx will be set by MW, there may be some SELinux policies to add.
Without the SELinux policies, I think we need 5 working days to implement it.
However, we still need detail Spec. to check.

(ALTech) Sangmin Choi

2024-03-27 09:07

developer   ~0015313

Hello, Kerwin,

Okay, I see, thank you for checking.
I will share the detail specification and schedule after discuss with SKB.

Thank you.
Sangmin Choi.

(SW) Kerwin Chen

2024-06-28 13:49

developer   ~0016122

Hi,

In order to implement this feature, I attach AML's remote module.
It contains Fii's modification for SKB RCUs.
After building the kernel module, you have to replace file in vendor/foxconn/prebuilts/module/remote.ko
Or replace ko file by adb remount for testing.
eagle_IR_Remote.zip (29,774 bytes)

(ALTech) Sangmin Choi

2024-06-28 16:17

developer   ~0016129

Hello, Kerwin,

Could you please share the build guide also?

Thank you.
Sangmin Choi.

(SW) Kerwin Chen

2024-06-28 19:33

developer   ~0016130

Last edited: 2024-06-28 19:36

Hi Mr. Sangmin Choi,

1. declare toolchain path
  export PATH=$PATH:/opt/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin
2. make kernel module
  make -C common M=../vendor/xxxx/drivers/remote O=../out/android-4.9/common ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- modules

(ALTech) Sangmin Choi

2024-07-01 16:26

developer   ~0016142

Last edited: 2024-07-01 16:29

Hello, Kerwin,

I can make your driver, please ignore it.

Thank you.
Sangmin Choi.
make_command.png (460,215 bytes)

(ALTech) Sangmin Choi

2024-07-05 11:59

developer   ~0016185

Hello, Kerwin,

I will reopen if I have any question.

Thank you.
Sangmin Choi.

(ALTech) Sangmin Choi

2024-07-10 08:43

developer   ~0016230

Hello, Kerwin,

Do you have any idea how to read/pass the android framework property(persist.sys.rcu.custom_ir_idx) from passive standby mode?
I've almost done this job but I don't know how to read it from passive standby mode.

Thank you.
Sangmin Choi.

(SW) Kerwin Chen

2024-07-10 11:26

developer   ~0016234

Hi Mr. Sangmin Choi,

Per updated in the post, you may need to check it with Amlogic.
(https://btracker-cns.fii-foxconn.com/vaas/view.php?id=1907#c15305)

As I know, system goes to another OS under passive standby mode.
I don't know how to communicate between Android and that OS.
Thanks.

(ALTech) Sangmin Choi

2024-07-11 13:46

developer   ~0016244

Hello, Kerwin,

Okay, I see.

Thank you.
Sangmin Choi.

Issue History

Date Modified Username Field Change
2024-03-26 13:09 (ALTech) Sangmin Choi New Issue
2024-03-26 13:12 (ALTech) Sangmin Choi Note Added: 0015299
2024-03-26 13:12 (ALTech) Sangmin Choi Assigned To => (SW) Kerwin Chen
2024-03-26 13:12 (ALTech) Sangmin Choi Status new => assigned
2024-03-26 13:12 (ALTech) Sangmin Choi Issue Monitored: (ALTech) Younkwang Jung
2024-03-26 13:12 (ALTech) Sangmin Choi Issue Monitored: (ALTech) JunGyu Kim
2024-03-26 13:12 (ALTech) Sangmin Choi Issue Monitored: (ALTech) Wooshin Kang
2024-03-26 15:02 (SW) Kerwin Chen Note Added: 0015304
2024-03-26 15:17 (SW) Kerwin Chen Note Added: 0015305
2024-03-26 15:18 (SW) Kerwin Chen Note Edited: 0015305
2024-03-26 15:37 (ALTech) Sangmin Choi Note Added: 0015307
2024-03-26 15:48 (ALTech) Sangmin Choi Note Edited: 0015307
2024-03-26 15:51 (ALTech) Sangmin Choi Note Edited: 0015307
2024-03-26 16:06 (ALTech) Sangmin Choi Note Added: 0015308
2024-03-26 16:06 (ALTech) Sangmin Choi Description Updated
2024-03-26 16:07 (ALTech) Sangmin Choi Note Edited: 0015307
2024-03-26 16:48 (SW) Kerwin Chen Note Added: 0015309
2024-03-26 17:06 (ALTech) Sangmin Choi Note Added: 0015310
2024-03-27 08:42 (SW) Kerwin Chen Note Added: 0015312
2024-03-27 09:07 (ALTech) Sangmin Choi Note Added: 0015313
2024-03-27 09:07 (ALTech) Sangmin Choi Assigned To (SW) Kerwin Chen => (ALTech) Sangmin Choi
2024-06-28 13:49 (SW) Kerwin Chen Note Added: 0016122
2024-06-28 13:49 (SW) Kerwin Chen File Added: eagle_IR_Remote.zip
2024-06-28 16:17 (ALTech) Sangmin Choi Note Added: 0016129
2024-06-28 19:33 (SW) Kerwin Chen Note Added: 0016130
2024-06-28 19:36 (SW) Kerwin Chen Note Edited: 0016130
2024-07-01 16:26 (ALTech) Sangmin Choi Note Added: 0016142
2024-07-01 16:26 (ALTech) Sangmin Choi File Added: make_command.png
2024-07-01 16:29 (ALTech) Sangmin Choi Note Edited: 0016142
2024-07-05 11:59 (ALTech) Sangmin Choi Status assigned => closed
2024-07-05 11:59 (ALTech) Sangmin Choi Resolution open => fixed
2024-07-05 11:59 (ALTech) Sangmin Choi Note Added: 0016185
2024-07-10 08:43 (ALTech) Sangmin Choi Assigned To (ALTech) Sangmin Choi => (SW) Kerwin Chen
2024-07-10 08:43 (ALTech) Sangmin Choi Status closed => feedback
2024-07-10 08:43 (ALTech) Sangmin Choi Resolution fixed => reopened
2024-07-10 08:43 (ALTech) Sangmin Choi Due Date 2024-04-01 13:00 => 2024-07-12 13:00
2024-07-10 08:43 (ALTech) Sangmin Choi Note Added: 0016230
2024-07-10 11:26 (SW) Kerwin Chen Note Added: 0016234
2024-07-11 13:46 (ALTech) Sangmin Choi Assigned To (SW) Kerwin Chen => (ALTech) Sangmin Choi
2024-07-11 13:46 (ALTech) Sangmin Choi Status feedback => closed
2024-07-11 13:46 (ALTech) Sangmin Choi Note Added: 0016244